package cn.com.pc.penguin.core;

import cn.com.pc.penguin.service.PenguinSearchResults;
import org.apache.lucene.document.Document;

import java.util.Collection;

/**
 * Created by IntelliJ IDEA.
 * User: huangqinghe
 * To change this template use File | Settings | File Templates.
 */
public interface SearchManager {
    public void init() throws Exception;
	public PenguinSearchResults search(PenguinArgs args) throws Exception;
	public void createIndex(Document doc) throws Exception;
	public void createIndex(Collection<Document> docs,Collection<String> ids) throws Exception;
	public void delete(String id) throws Exception;
	public void delete(Collection<String> ids) throws Exception;
	public void notifyNewDocumentAdded() throws Exception;
	public void commit() throws Exception;
}
